<?php
class Nous_mdl extends CI_Model
{
	function __construct()
	{
		parent::__construct();
	}
	
	public function getNousById($p_id)
	{
		$strSql = 'SELECT nuos_title,nous_author,nous_date,nous_content From dili_u_m_nous WHERE id ='.$p_id;
		$arr    = $this->db->query($strSql)->result->array();
		
		return $arr[0];
	}
	
	public function getAllNous($p_page = 10,$p_begin = 0)
	{
		$strSql = 'SELECT nuos_title,nous_author,nous_date,nous_content From dili_u_m_nous group by id limit '.$p_begin.','.$p_page;
		$arr    = $this->db->query($strSql)->result->array();
		
		return $arr;
	}
}